<!DOCTYPE html>
<html lang="en">

<head>
    <meta charset="UTF-8">
    <title>上传</title>
    <!-- 引入样式 -->
    <link rel="stylesheet" href="https://unpkg.com/element-ui/lib/theme-chalk/index.css">
    <!-- 引入组件库 -->
    <script src="https://apps.bdimg.com/libs/jquery/2.1.4/jquery.min.js"></script>
    <!-- 开发环境版本，包含了有帮助的命令行警告 -->
    <script src="https://cdn.jsdelivr.net/npm/axios/dist/axios.min.js"></script>
    <script src="https://cdn.jsdelivr.net/npm/vue@2/dist/vue.js"></script>
</head>

<body>

    <div id="app">
        <div class="list">
            <ul>
                <li v-for="item in url_list">{{item.data.fileName}}
                </li>
            </ul>
        </div>
    </div>
    <script>
        // const axios = require('axios').default;

        var app = new Vue({
            el: "#app",
            data: {

                url_list: []
            },

            methods: {
                getall: function () {

                    var url = 'http://127.0.0.1:8989/hphotos?callback=?';
                    $.ajax({
                        url: url,
                        dataType: 'jsonp',
                        processData: false,
                        type: 'get',
                        success: function (data) {
                            alert(data.url);
                        },
                        error: function (XMLHttpRequest, textStatus, errorThrown) {
                            alert(XMLHttpRequest.status);
                            alert(XMLHttpRequest.readyState);
                            alert(textStatus);
                        }
                    });

                }


            },
            created() {
                console.log("执行");
                this.getall();

            }
        })
    </script>
</body>

</html>